package com.itheima.output;

import java.io.FileInputStream;
import java.io.FileOutputStream;
import java.io.IOException;

public class OutputDemo04 {
    public static void main(String[] args) throws IOException {
        FileInputStream fis = new FileInputStream("D:\\dev\\a.txt");
        FileOutputStream fos = new FileOutputStream("day12_file&字节流\\a.txt");

        byte[] bytes = new byte[1024];
        int len;

        while ((len = fis.read(bytes)) != -1) {
            fos.write(bytes, 0, len);
        }

        fis.close();
        fos.close();
    }
}
